const search = document.querySelector('.search')
const searchBtn = document.querySelector('.btn')
const searchInput = document.querySelector('.input')

searchBtn.addEventListener('click', function() {
    if (search.classList.contains('active')) {
        search.classList.remove('active')
    } else {
        search.classList.add('active')
        searchInput.focus()
    }
})